<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <!-- 最新版本的 Bootstrap 核心 CSS 文件 -->
    <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css"
        integrity="sha384-HSMxcRTRxnN+Bdg0JdbxYKrThecOKuH5zCYotlSAcp1+c8xmyTe9GYg1l9a69psu" crossorigin="anonymous">
    <!-- jQuery文件 -->
    <script src="http://libs.baidu.com/jquery/2.0.0/jquery.min.js"></script>
    <!-- 最新的 Bootstrap 核心 JavaScript 文件 -->
    <script src="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js"
        integrity="sha384-aJ21OjlMXNL5UyIl/XNwTMqvzeRMZH2w8c5cRVpzpU8Y5bApTppSuUkhZXN0VxHd"
        crossorigin="anonymous">
    </script>


    <style>
        .main {
            width: 800px;
            margin: 0 auto;
            margin-top: 200px;
        }
    </style>
</head>

<body>
    <div class="main">

        <form class="form-horizontal">
            <div class="form-group">
                <label for="inputEmail3" class="col-sm-2 control-label">Username</label>
                <div class="col-sm-10">
                    <input type="text" class="form-control  input01" id="inputEmail3" placeholder="Username">
                </div>
            </div>
            <div class="form-group">
                <label for="inputPassword3" class="col-sm-2 control-label">Password</label>
                <div class="col-sm-10">
                    <input type="password" class="form-control input02" id="inputPassword3" placeholder="Password">
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-offset-2 col-sm-10">
                    <button type="button" class="btn btn-default Signin">Sign in</button>
                    <button type="button" class="btn btn-default Register">Register</button>
                </div>
            </div>
        </form>
    </div>

    <script>
        let signin = document.querySelector('.Signin')
        let register = document.querySelector('.Register')
        let input01 = document.querySelector('.input01')
        let input02 = document.querySelector('.input02')

        let startUrl = 'http://192.168.12.56:9999'


        signin.onclick = function () {
            console.log(111)
            console.log(input01.value)
            window.location.href = `${startUrl}?username=${input01.value}&passwd=${input02.value}`
        }
        register.onclick = function () {
            console.log(input02.value)
            window.location.href = `${startUrl}?username=$${input01.value}&passwd=${input02.value}`
        }
    </script>
</body>

</html>j